package com.appkubes.mall.core.pojo;

import com.appkubes.mall.core.po.MallAdmin;
import com.appkubes.mall.core.po.MallAdminExample;
import java.util.List;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.DeleteProvider;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.InsertProvider;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.SelectProvider;
import org.apache.ibatis.annotations.Update;
import org.apache.ibatis.annotations.UpdateProvider;
import org.apache.ibatis.session.RowBounds;
import org.apache.ibatis.type.JdbcType;

public interface MallAdminMapper {
    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @SelectProvider(type=MallAdminSqlProvider.class, method="countByExample")
    long countByExample(MallAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @DeleteProvider(type=MallAdminSqlProvider.class, method="deleteByExample")
    int deleteByExample(MallAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @Delete({
        "delete from mall_admin",
        "where admin_key = #{adminKey,jdbcType=VARCHAR}"
    })
    int deleteByPrimaryKey(String adminKey);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @Insert({
        "insert into mall_admin (admin_key, app_key, ",
        "img, nick_name, `name`, ",
        "create_time, update_time, ",
        "login_time, user_name, ",
        "`password`, verify_code, ",
        "mobile, `state`, version)",
        "values (#{adminKey,jdbcType=VARCHAR}, #{appKey,jdbcType=VARCHAR}, ",
        "#{img,jdbcType=VARCHAR}, #{nickName,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, ",
        "#{createTime,jdbcType=INTEGER}, #{updateTime,jdbcType=INTEGER}, ",
        "#{loginTime,jdbcType=INTEGER}, #{userName,jdbcType=VARCHAR}, ",
        "#{password,jdbcType=VARCHAR}, #{verifyCode,jdbcType=VARCHAR}, ",
        "#{mobile,jdbcType=VARCHAR}, #{state,jdbcType=INTEGER}, #{version,jdbcType=INTEGER})"
    })
    int insert(MallAdmin record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @InsertProvider(type=MallAdminSqlProvider.class, method="insertSelective")
    int insertSelective(MallAdmin record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @SelectProvider(type=MallAdminSqlProvider.class, method="selectByExample")
    @Results({
        @Result(column="admin_key", property="adminKey", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="app_key", property="appKey", jdbcType=JdbcType.VARCHAR),
        @Result(column="img", property="img", jdbcType=JdbcType.VARCHAR),
        @Result(column="nick_name", property="nickName", jdbcType=JdbcType.VARCHAR),
        @Result(column="name", property="name", jdbcType=JdbcType.VARCHAR),
        @Result(column="create_time", property="createTime", jdbcType=JdbcType.INTEGER),
        @Result(column="update_time", property="updateTime", jdbcType=JdbcType.INTEGER),
        @Result(column="login_time", property="loginTime", jdbcType=JdbcType.INTEGER),
        @Result(column="user_name", property="userName", jdbcType=JdbcType.VARCHAR),
        @Result(column="password", property="password", jdbcType=JdbcType.VARCHAR),
        @Result(column="verify_code", property="verifyCode", jdbcType=JdbcType.VARCHAR),
        @Result(column="mobile", property="mobile", jdbcType=JdbcType.VARCHAR),
        @Result(column="state", property="state", jdbcType=JdbcType.INTEGER),
        @Result(column="version", property="version", jdbcType=JdbcType.INTEGER)
    })
    List<MallAdmin> selectByExampleWithRowbounds(MallAdminExample example, RowBounds rowBounds);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @SelectProvider(type=MallAdminSqlProvider.class, method="selectByExample")
    @Results({
        @Result(column="admin_key", property="adminKey", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="app_key", property="appKey", jdbcType=JdbcType.VARCHAR),
        @Result(column="img", property="img", jdbcType=JdbcType.VARCHAR),
        @Result(column="nick_name", property="nickName", jdbcType=JdbcType.VARCHAR),
        @Result(column="name", property="name", jdbcType=JdbcType.VARCHAR),
        @Result(column="create_time", property="createTime", jdbcType=JdbcType.INTEGER),
        @Result(column="update_time", property="updateTime", jdbcType=JdbcType.INTEGER),
        @Result(column="login_time", property="loginTime", jdbcType=JdbcType.INTEGER),
        @Result(column="user_name", property="userName", jdbcType=JdbcType.VARCHAR),
        @Result(column="password", property="password", jdbcType=JdbcType.VARCHAR),
        @Result(column="verify_code", property="verifyCode", jdbcType=JdbcType.VARCHAR),
        @Result(column="mobile", property="mobile", jdbcType=JdbcType.VARCHAR),
        @Result(column="state", property="state", jdbcType=JdbcType.INTEGER),
        @Result(column="version", property="version", jdbcType=JdbcType.INTEGER)
    })
    List<MallAdmin> selectByExample(MallAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @Select({
        "select",
        "admin_key, app_key, img, nick_name, `name`, create_time, update_time, login_time, ",
        "user_name, `password`, verify_code, mobile, `state`, version",
        "from mall_admin",
        "where admin_key = #{adminKey,jdbcType=VARCHAR}"
    })
    @Results({
        @Result(column="admin_key", property="adminKey", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="app_key", property="appKey", jdbcType=JdbcType.VARCHAR),
        @Result(column="img", property="img", jdbcType=JdbcType.VARCHAR),
        @Result(column="nick_name", property="nickName", jdbcType=JdbcType.VARCHAR),
        @Result(column="name", property="name", jdbcType=JdbcType.VARCHAR),
        @Result(column="create_time", property="createTime", jdbcType=JdbcType.INTEGER),
        @Result(column="update_time", property="updateTime", jdbcType=JdbcType.INTEGER),
        @Result(column="login_time", property="loginTime", jdbcType=JdbcType.INTEGER),
        @Result(column="user_name", property="userName", jdbcType=JdbcType.VARCHAR),
        @Result(column="password", property="password", jdbcType=JdbcType.VARCHAR),
        @Result(column="verify_code", property="verifyCode", jdbcType=JdbcType.VARCHAR),
        @Result(column="mobile", property="mobile", jdbcType=JdbcType.VARCHAR),
        @Result(column="state", property="state", jdbcType=JdbcType.INTEGER),
        @Result(column="version", property="version", jdbcType=JdbcType.INTEGER)
    })
    MallAdmin selectByPrimaryKey(String adminKey);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @UpdateProvider(type=MallAdminSqlProvider.class, method="updateByExampleSelective")
    int updateByExampleSelective(@Param("record") MallAdmin record, @Param("example") MallAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @UpdateProvider(type=MallAdminSqlProvider.class, method="updateByExample")
    int updateByExample(@Param("record") MallAdmin record, @Param("example") MallAdminExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @UpdateProvider(type=MallAdminSqlProvider.class, method="updateByPrimaryKeySelective")
    int updateByPrimaryKeySelective(MallAdmin record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_admin
     *
     * @mbg.generated
     */
    @Update({
        "update mall_admin",
        "set app_key = #{appKey,jdbcType=VARCHAR},",
          "img = #{img,jdbcType=VARCHAR},",
          "nick_name = #{nickName,jdbcType=VARCHAR},",
          "`name` = #{name,jdbcType=VARCHAR},",
          "create_time = #{createTime,jdbcType=INTEGER},",
          "update_time = #{updateTime,jdbcType=INTEGER},",
          "login_time = #{loginTime,jdbcType=INTEGER},",
          "user_name = #{userName,jdbcType=VARCHAR},",
          "`password` = #{password,jdbcType=VARCHAR},",
          "verify_code = #{verifyCode,jdbcType=VARCHAR},",
          "mobile = #{mobile,jdbcType=VARCHAR},",
          "`state` = #{state,jdbcType=INTEGER},",
          "version = #{version,jdbcType=INTEGER}",
        "where admin_key = #{adminKey,jdbcType=VARCHAR}"
    })
    int updateByPrimaryKey(MallAdmin record);
}